# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=aqemu
pkgver=0.9.4
pkgrel=3
pkgdesc="GUI for virtual machines using QEMU as the backend"
url="https://sourceforge.net/projects/aqemu/"
arch="all"
license="GPL-2.0-only"
depends="qemu"
options="!check" #no check/test provided
makedepends="
	cmake
	glib-dev
	libvncserver-dev
	qt5-qtbase-dev
	samurai
	"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/TBK/aqemu/archive/v$pkgver.tar.gz
	appdata.patch
	fix-includes.patch
	fix-qt-segfault.patch
	"

build() {
	cmake -B build -G Ninja \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_BUILD_TYPE=None
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
e10e2c558572e6194abadeb46034a59d1b5837efe77012c2ef2d4c5ae610e7a7b09e2315e6d5fd8a12fd7f9db34068a15926b0dbe8f91db6a0d4f48eea722a9d  aqemu-0.9.4.tar.gz
2a711dc5935e2d5d5fb825b2209ce8f206bc178bc4af3b21e7be8220963fd2c68a529c94bea86333331dfd5557104101a17fd68f701b8288926878449dafaf7b  appdata.patch
3220e25280a5728f299f30147c0a78537a672541a0c561aedad10af38650ef0a9145d7898060230147878fa497320ab789310b055c018a59f6474f588c4a042b  fix-includes.patch
61d7982877392a9224add9448466273f6e485bc6b9dc85339159f27647312bb6ef6f4467d74dd6aa6b4e77aaea4ab03d4e8a3b4d4363bdb119334a3aeeb255c9  fix-qt-segfault.patch
"
